Complex Brain Networks: A Graph-Theoretical Analysis

231

A scale-free network can be constructed using the following steps [5]:

1.

Growth: A new node is added to network at each step.

2.

Preferential Attachment: A new node u is attached to any node

v in the network with a probability proportional to the degree of

v. Applying this rule ensures that higher degree nodes will have

relatively more neighbors eventually. This mode of operation is

known as “rich gets richer” principle.

Hierarchical Networks: Analysis of complex brain networks reveals an inter-

esting property: Dense clusters of low-degree nodes are connected by high-

degree nodes called hubs providing a hierarchical network structure. The

complex brain networks show small-world and scale-free properties in this

hierarchical structure.

9.3.6

Network Analysis with Python

Complex networks can be analyzed, constructed and visualized using the

programming language Python which provides a library called networkx

for this purpose. Using this module, a random network may be con-

structed by the erdos_renyi_graph method and a small-world network

by the watts_strogatz_graph method; and a scale-free network by the al-

bert_barabasi_graph method as shown in the following Python code. Graphs

with 20 nodes built using these algorithms are displayed in Figure 9.3 and

Figure 9.4.

1

import networkx as nx

2

import matplotlib.pyplot as plt

3

4

G=nx.erdos_renyi_graph(20,0.4) # 0.4: probability of connection

5

nx.draw(G,with_labels=1)

6

plt.show()

7

8

G=nx.watts_strogatz_graph(20,5,0.5) # 5 connections, 0.5 probability

9

pos=nx.circular_layout(G)

10

nx.draw(G,pos,with_labels=True)

11

plt.show()

12

13

G=nx.barabasi_albert_graph(20,2) # Average 2 connections

14

nx.draw(G,with_labels=1)

15

plt.show()